package com.frank.oj.service.admin.contest;

import com.frank.model.entity.contest.ContestProblem;
import com.frank.model.entity.problem.Problem;
import com.frank.oj.common.exception.StatusFailException;
import com.frank.oj.common.exception.StatusForbiddenException;
import com.frank.oj.common.result.CommonResult;
import com.frank.oj.model.dto.ContestProblemDTO;
import com.frank.oj.model.dto.ProblemDTO;

import java.util.HashMap;
import java.util.Map;

/**
 * @author frank
 * @Date 2024/4/7
 */
public interface AdminContestProblemService {
    CommonResult<HashMap<String, Object>> getProblemList(Integer limit, Integer currentPage, String keyword, Long cid, Integer problemType, String oj);

    CommonResult<Problem> getProblem(Long pid);

    CommonResult<ContestProblem> getContestProblem(Long cid, Long pid);

    CommonResult<Void> deleteProblem(Long pid, Long cid);

    CommonResult<Map<Object, Object>> addProblem(ProblemDTO problemDto);

    CommonResult<Void> updateProblem(ProblemDTO problemDto);

    CommonResult<ContestProblem> setContestProblem(ContestProblem contestProblem);

    CommonResult<Void> addProblemFromPublic(ContestProblemDTO contestProblemDto);

    CommonResult<Void> importContestRemoteOJProblem(String name, String problemId, Long cid, String displayId);
}
